package com.netease.cloud.cm.api;

import com.netease.cloud.cm.common.Constants;
import com.netease.cloud.cm.model.response.ServerVersionResponse;
import retrofit2.Call;
import retrofit2.http.HTTP;
import retrofit2.http.Headers;
import retrofit2.http.QueryMap;

import java.util.Map;

/**
 * 服务器版本号相关接口定义
 */
public interface ServerVersionService {

	/**
	 * 静态添加header
	 *
	 * @return
	 */
	@Headers({Constants.HEADER_REQUEST_ID, Constants.HEADER_LANGUAGE_EN})
	@HTTP(method = "GET", path = "ncm/admin?Action=QueryServerVersion&Version=2019-04-01")
	Call<ServerVersionResponse> queryService1();

	/**
	 * 动态添加header
	 *
	 * @param map
	 * @return
	 */
	@Headers({Constants.HEADER_REQUEST_ID, Constants.HEADER_LANGUAGE_EN})
	@HTTP(method = "GET", path = "ncm/admin")
	Call<ServerVersionResponse> queryService2(@QueryMap Map<String, Object> map);
}
